<!DOCTYPE html>
<html>
    <head>
        <meta charset="utf-8">
        <title></title>
        <script src="../vue.js" type="text/javascript" charset="utf-8"></script>
    </head>
    <body>
        <div id="app">
            <button v-on:click="counter += 1">数值 ： {{counter}}</button><br/>
            <button v-on:click="greet('abc', $event)">Greet</button>
        </div>
        <script type="text/javascript">
            var app = new Vue({
                el: '#app',
                data: {
                    counter: 0,
                    name: "vue"
                },
                methods: {
                    greet: function(str, e) {
                        alert(this.name);
                        alert(str);
                        console.log(e);
                    }
                }
            })
        </script>
        <style type="text/css">
        </style>
    </body>
</html>